<div id="side">
    <div id="subnav">
        <div class="top"></div>
        <div class="body">

        <?php foreach($categories as $c): ?>

                <h3 class="<?php echo 'title-'.$c['css_class'] ?>"><?php echo $c['name'] ?></h3>
                <?php if($c['has_children']): ?>
                <ul class="<?php echo $c['css_class'] ?>">
                    <?php $i=1; ?>
                    <?php foreach ($c['children'] as $slug => $c2): ?>
                    <li <?php if($i==count($c['children'])) echo "class='last'" ?>><?php echo link_to($c2['name'], 'category_show', array('slug'=>$slug), array('title'=>$c2['name'])) ?></li>
                    <?php $i++ ?>
                    <?php endforeach ?>

                </ul>
                <?php endif ?>



        <?php endforeach;  ?>


        </div>
        <div class="bottom"></div>
    </div>


        <div id="banner-area">
                <?php include_partial('common/sitezone', array('zone'=>$sidebar)) ?>
        </div>

    </div>